package com.project.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.project.bean.StudentBean;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface IStudentMapper extends BaseMapper<StudentBean> {

    public IPage<StudentBean> findByItem(Page page, @Param("stuName") String stuName, @Param("className") String className, @Param("roomAddress") String roomAddress);


    public void changeRoom(@Param("stuId") Integer stuId, @Param("roomId") Integer roomId);

//    public int countByRoom(@Param("roomId") int roomId);

    public List<StudentBean> findStuByRoomId(@Param("roomId") Integer roomId);

//    public int countByClass(@Param("classId") int classId);

    public StudentBean findById(Integer stuId);
}
